:root {
    --primary-color: #4361ee;
    --secondary-color: #3a56d9;
    --error-color: #ff4757;
    --light-color: #f8f9fa;
    --dark-color: #212529;
    --gray-color: #6c757d;
}

body {
    background-color: #f5f7ff;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0;
    background-image:url(https://witmore.oss-cn-hangzhou.aliyuncs.com/img/bg/ai-bg-1s.jpg);
    background-size:cover;
    background-repeat: no-repeat;
}

.login-container {
    width: 100%;
    max-width: 400px;
    padding: 40px;
    background: white;
    border-radius: 12px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
}

.login-header {
    text-align: center;
    margin-bottom: 20px;
}

.logo {
    width: 80px;
    height: 80px;
    margin: 0 auto 20px;
    border-radius: 50%;
    background-color: var(--primary-color);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 2rem;
}

.login-header h2 {
    font-weight: 600;
    color: var(--dark-color);
    margin-bottom: 10px;
    font-size: 1.8rem;
}

.login-header p {
    color: var(--gray-color);
    margin: 0;
    font-size: 0.95rem;
}

.form-group {
    margin-bottom: 10px;
}

.input-field {
    width: 100%;
    padding: 12px 15px;
    box-sizing: border-box;
    border: 1px solid #e0e6ed;
    border-radius: 6px;
    font-size: 0.95rem;
    transition: all 0.3s;
}

.input-field:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(67, 97, 238, 0.15);
    outline: none;
}

.input-label {
    display: block;
    margin-bottom: 5px;
    font-size: 0.9rem;
    color: var(--dark-color);
    font-weight: 500;
}

.highlight-box {
    border-radius: 6px;
    padding: 2px;
    box-sizing: border-box;
    margin-bottom: 10px;
}

.remember-me {
    padding:10px 0;
    padding-bottom:5px;
}

.btn-login {
    width: 100%;
    padding: 12px;
    background-color: var(--primary-color);
    color: white;
    border: none;
    border-radius: 6px;
    font-weight: 500;
    font-size: 1rem;
    cursor: pointer;
    transition: background-color 0.3s;
}

.btn-login:hover {
    background-color: var(--secondary-color);
}

.error-message {
    color: var(--error-color);
    font-size: 0.9rem;
    margin-top: 15px;
    text-align: center;
}

/* 其他登录方式 */
.other-login {
    margin-top: 20px;
    text-align: center;
}

.divider {
    position: relative;
    margin: 20px 0;
    text-align: center;
}

.divider::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    height: 1px;
    background-color: #e0e6ed;
}

.divider span {
    background-color: white;
    padding: 0 15px;
    color: var(--gray-color);
    font-size: 0.85rem;
    position: relative;
    z-index: 1;
}

.sms-login-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--primary-color);
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    padding: 8px 16px;
    border-radius: 6px;
    transition: all 0.3s ease;
    border: 1px solid transparent;
}

.sms-login-link:hover {
    background-color: rgba(67, 97, 238, 0.05);
    border-color: rgba(67, 97, 238, 0.2);
    text-decoration: none;
    color: var(--secondary-color);
}

.sms-login-link i {
    font-size: 1rem;
}

/* 验证码登录页面专用样式 */
.code-input-group {
    display: flex;
    gap: 8px;
    align-items: flex-end;
}

.code-input-group .highlight-box {
    flex: 1;
    margin-bottom: 0;
}

.btn-send-code {
    padding: 12px 12px;
    background-color: var(--primary-color);
    color: white;
    border: none;
    border-radius: 6px;
    font-size: 0.85rem;
    font-weight: 500;
    cursor: pointer;
    transition: background-color 0.3s;
    white-space: nowrap;
    min-width: 90px;
    flex-shrink: 0;
}

.btn-send-code:hover:not(:disabled) {
    background-color: var(--secondary-color);
}

.btn-send-code:disabled {
    background-color: var(--gray-color);
    cursor: not-allowed;
}

/* 短信登录提示 */
.sms-tip {
    margin: 15px 0;
    padding: 12px;
    background-color: rgba(67, 97, 238, 0.05);
    border-left: 4px solid var(--primary-color);
    border-radius: 4px;
}

.sms-tip p {
    margin: 0;
    font-size: 0.85rem;
    color: var(--gray-color);
    display: flex;
    align-items: center;
    gap: 8px;
}

.sms-tip i {
    color: var(--primary-color);
    font-size: 0.9rem;
}

/* 移动端优化 */
@media (max-width: 768px) {
    body {
        padding: 10px;
        align-items: flex-start;
        justify-content: center;
        min-height: 100vh;
        height: auto;
    }
    
    .login-container {
        max-width: 100%;
        width: 100%;
        padding: 20px;
        margin: 20px 0;
        border-radius: 8px;
        box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    }
    
    .logo {
        width: 60px;
        height: 60px;
        font-size: 1.5rem;
        margin-bottom: 15px;
    }
    
    .login-header h2 {
        font-size: 1.5rem;
        margin-bottom: 8px;
    }
    
    .login-header p {
        font-size: 0.9rem;
        line-height: 1.4;
    }
    
    .input-field {
        padding: 14px 12px;
        font-size: 16px; /* 防止iOS缩放 */
        border-radius: 8px;
    }
    
    .btn-login {
        padding: 14px;
        font-size: 16px;
        border-radius: 8px;
        margin-top: 10px;
    }
    
    .btn-send-code {
        padding: 14px 10px;
        font-size: 13px;
        border-radius: 8px;
        min-width: 80px;
    }
    
    .sms-tip {
        margin: 12px 0;
        padding: 10px;
    }
    
    .sms-tip p {
        font-size: 0.8rem;
        line-height: 1.3;
    }
}

@media (max-width: 480px) {
    body {
        padding: 5px;
    }
    
    .login-container {
        padding: 15px;
        margin: 10px 0;
    }
    
    .form-group {
        margin-bottom: 15px;
    }
    
    .other-login {
        margin-top: 15px;
    }
}

@media (max-width: 360px) {
    .login-container {
        padding: 12px;
    }
    
    .logo {
        width: 50px;
        height: 50px;
        font-size: 1.2rem;
    }
    
    .login-header h2 {
        font-size: 1.3rem;
    }
    
    .login-header p {
        font-size: 0.85rem;
    }
    
    /* 只在很小的屏幕上才垂直排列 */
    .code-input-group {
        flex-direction: column;
        gap: 10px;
    }
    
    .btn-send-code {
        width: 100%;
        min-width: auto;
    }
}